<template>
    <div class="m-title flex flex-y">
        <div v-if="noBack == null" class="flex flex-y left" @click="$router.back()">
            <i class="el-icon-arrow-left backIcon" />
            <span>返回</span>
        </div>
        <h3 class="middle">{{ title || $route.meta.title||'砂锅号总后台' }}</h3>
    </div>
</template>

<script>
export default {
    props: {
        title: undefined,
        noBack: { default: null }
    },
    data () {
        return {}
    }
}
</script>

<style lang="scss" scoped>
.m-title {
    position: relative;
    width: 100%;
    height: 62px;
    // border-bottom: solid 1px #ddd;
    background-color: #fff;
    text-align: center;
    .left {
        position: absolute;
        left: 15px;
        color: #999;
        cursor: pointer;
    }
    .middle {
        margin: 0 auto;
        font-size: 17px;
    }
    .backIcon {
        margin-right: 4px;
    }
}
</style>
